<template>
    <el-row class="tac">
        <el-col :span="24">
            <el-menu default-active="2" :router="true" class="el-menu-vertical-demo" @open="handleOpen" @close="handleClose" background-color="#545c64" text-color="#fff" active-text-color="#3490de">
                <el-menu-item index="/All/orderCalculation">
                    <i class="el-icon-pie-chart"></i>
                    <span slot="title">统计</span>
                </el-menu-item>

                <el-submenu index="2">
                    <template slot="title">
                        <i class="el-icon-box"></i>
                        <span>商品管理</span>
                    </template>
                    <el-menu-item-group>
                        <el-menu-item index="/All/goodsList">商品列表</el-menu-item>
                        <el-menu-item index="/All/addGoods">新增商品</el-menu-item>
                        <el-menu-item index="/All/goodsType">商品类别</el-menu-item>
                        <!-- <el-menu-item index="1-2"><router-link to="/All/goods" tag="span">商品</router-link></el-menu-item> -->
                    </el-menu-item-group>
                </el-submenu>
                <el-submenu index="3">
                    <template slot="title">
                        <i class="el-icon-shopping-cart-full"></i>
                        <span>订单管理</span>
                    </template>
                    <el-menu-item-group>
                        <el-menu-item index="/All/order"> 全部订单</el-menu-item>
                        <el-menu-item index="/All/order/1">未发货订单</el-menu-item>
                        <el-menu-item index="/All/order/2">已发货订单</el-menu-item>
                        <el-menu-item index="/All/order/3">已取消订单</el-menu-item>
                    </el-menu-item-group>
                </el-submenu>
                <el-submenu index="4">
                    <template slot="title">
                        <i class="el-icon-user"></i>
                        <span>用户管理</span>
                    </template>
                    <el-menu-item-group>
                        <el-menu-item><router-link to="/All/adminList" tag="span">管理员列表</router-link> </el-menu-item>
                        <el-menu-item><router-link to="/All/adminAdd" tag="span">管理员新增</router-link></el-menu-item>
                    </el-menu-item-group>
                </el-submenu>
                <el-submenu index="6">
                    <template slot="title">
                        <i class="el-icon-s-ticket"></i>
                        <span>文章管理</span>
                    </template>
                    <el-menu-item-group>
                        <el-menu-item><router-link to="/All/articalList" tag="span">文章列表</router-link> </el-menu-item>
                        <el-menu-item><router-link to="/All/articalAdd" tag="span">新增文章</router-link></el-menu-item>
                    </el-menu-item-group>
                </el-submenu>
                <el-submenu index="5">
                    <template slot="title">
                        <i class="el-icon-setting"></i>
                        <span>网站设置</span>
                    </template>
                    <el-menu-item-group>
                        <el-menu-item index="/All/Ad"><router-link to="/All/Ad" tag="span">广告幻灯片</router-link></el-menu-item>
                       
                    </el-menu-item-group>
                </el-submenu>
            </el-menu>
        </el-col>
    </el-row>
</template>

<script>
export default {
    methods: {
        handleOpen(key, keyPath) {
            console.log(key, keyPath);
        },
        handleClose(key, keyPath) {
            console.log(key, keyPath);
        }
    }
};
</script>

<style>
.tac {
    overflow: hidden;
}
.tac,
.el-col,
.el-menu-vertical-demo {
    height: 100vh;
}
</style>
